package com.sure0000.practice;

import org.junit.Test;

import java.util.ArrayList;
import java.util.List;

/**
 * @author xuyouchang
 * @date 2020/11/5.
 */
public class DeleteListAndArray {

    @Test
    public void delList() {
        List<String> testList = new ArrayList<>();
        testList.add("a");
        testList.add("b");
        testList.add("c");
        for (int i = 0; i < testList.size(); i++) {
            testList.remove(testList.get(i));
            i--;
            System.out.println(testList);
        }
    }

    @Test
    public void delArray() {
        String[] arr = {"a", "b", "c"};

    }
}
